package cn.edu.ujn.food.dao;

import cn.edu.ujn.food.entity.Review;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.data.domain.Pageable;
import java.util.List;
@Mapper
public interface ReviewDao {

    Review queryById(Integer reviewId);

    List<Review> queryAllByLimit(Review review, @Param("pageable") Pageable pageable);

    long count(Review review);

    int insert(Review review);

    int insertBatch(@Param("entities") List<Review> entities);

    int insertOrUpdateBatch(@Param("entities") List<Review> entities);

    int update(Review review);

    int deleteById(Integer reviewId);

    List<Review> selectAll(Review review);

    Integer selectCount();
}

